package com.gzhryc.shared_device.oem.code.user.dao.db;

import com.gzhryc.jdbc.annotaion.Column;
import com.gzhryc.jdbc.annotaion.PrimaryKey;
import com.gzhryc.jdbc.annotaion.Table;
import com.gzhryc.shared_device.common.payment.dao.enums.WXPayConfigEnum;

import java.util.Date;

/**
 * 微信用户，用于提现
 * @version 2023-01-4
 */
@Table(name="user_transfer_money_wx")
public class UserTransferMoneyWX {

    @PrimaryKey
    @Column(name = "appId",note = "微信应用ID")
    protected String appId;

    @PrimaryKey
    @Column(name = "open_id",note = "微信OpenID")
    protected String openId;

    @PrimaryKey
    @Column(name = "user_id", notNull = true,note = "用户ID")
    protected Long userId;

    @Column(name="app_type",notNull = true,note = "应用类型")
    protected Integer appType;

    @Column(name="nickname",note = "微信用户昵称")
    protected String nickname;

    @Column(name="face_img",length = 255,note = "微信用户头像")
    protected String faceImg;

    @Column(notNull = true,defVal = "1",note = "性别")
    protected Integer sex;

    @Column(name="country",note = "国家，如中国为CN")
    private String country;

    @Column(name="province",note = "用户个人资料填写的省份")
    private String province;

    @Column(name="city",note = "普通用户个人资料填写的城市")
    private String city;

    @Column(name="name",note = "用户姓名")
    protected String name;

    @Column(name="phone",length = 16,note = "微信用户手机号")
    protected String phone;

    @Column(name = "update_date", autoUpdateTime = true)
    protected Date updateDate;

    @Column(name = "create_date")
    protected Date createDate;

    public String getAppId() {
        return appId;
    }

    public void setAppId(String appId) {
        this.appId = appId;
    }

    public String getOpenId() {
        return openId;
    }

    public void setOpenId(String openId) {
        this.openId = openId;
    }

    public Long getUserId() {
        return userId;
    }

    public void setUserId(Long userId) {
        this.userId = userId;
    }

    public Integer getAppType() {
        return appType;
    }

    public void setAppType(Integer appType) {
        this.appType = appType;
    }

    public String getNickname() {
        return nickname;
    }

    public void setNickname(String nickname) {
        this.nickname = nickname;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getFaceImg() {
        return faceImg;
    }

    public void setFaceImg(String faceImg) {
        this.faceImg = faceImg;
    }

    public Integer getSex() {
        return sex;
    }

    public void setSex(Integer sex) {
        this.sex = sex;
    }

    public String getCountry() {
        return country;
    }

    public void setCountry(String country) {
        this.country = country;
    }

    public String getProvince() {
        return province;
    }

    public void setProvince(String province) {
        this.province = province;
    }

    public String getCity() {
        return city;
    }

    public void setCity(String city) {
        this.city = city;
    }

    public String getPhone() {
        return phone;
    }

    public void setPhone(String phone) {
        this.phone = phone;
    }

    public Date getUpdateDate() {
        return updateDate;
    }

    public void setUpdateDate(Date updateDate) {
        this.updateDate = updateDate;
    }

    public Date getCreateDate() {
        return createDate;
    }

    public void setCreateDate(Date createDate) {
        this.createDate = createDate;
    }

    public String getAppTypeName(){
        return WXPayConfigEnum.AppType.note(this.appType);
    }
}
